﻿using Basic.HrGatewayModular.Interface;
using Basic.HrRemoteModel.EmpPost;
using Basic.HrRemoteModel.EmpPost.Model;

namespace Basic.HrGatewayModular.Services
{
    internal class EmpPostService : IEmpPostService
    {
        public long Add ( EmpPostAdd datum )
        {
            return new AddEmpPost
            {
                Datum = datum,
            }.Send();
        }

        public void Delete ( long id )
        {
            new DeleteEmpPost
            {
                Id = id,
            }.Send();
        }

        public EmpPostData Get ( long id )
        {
            return new GetEmpPost
            {
                Id = id,
            }.Send();
        }

        public EmpPostDatum[] Gets ( long empId, long companyId )
        {
            return new GetEmpPostList
            {
                EmpId = empId,
                CompanyId = companyId
            }.Send();
        }
    }
}
